package com.example.warehouse_manager.service.impl;

import com.example.warehouse_manager.entity.Supply;
import com.example.warehouse_manager.mapper.SupplyMapper;
import com.example.warehouse_manager.service.SupplyService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.cache.annotation.CacheConfig;
import org.springframework.cache.annotation.Cacheable;
import org.springframework.stereotype.Service;

import java.util.List;

/**
* @author Yang
* @description 针对表【supply(供货商)】的数据库操作Service实现
* @createDate 2024-03-22 14:06:15
*/
//@CacheConfig(cacheNames = "com.example.warehouse_manager.service.impl.SupplyServiceImpl")
@Service
public class SupplyServiceImpl implements SupplyService{

    @Autowired
    private SupplyMapper supplyMapper;

    //查询所有供应商
    //@Cacheable(key = "'all:supply'")
    @Override
    public List<Supply> queryAllSupply() {
        return supplyMapper.findAllSupply();
    }


}




